Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
if (cspec)
return cspec->cmd_impl(argc, argv);
else if (!strcmp(cmd, "help")) {
- help(argv[2]);
+ help(argv[optind]);
exit(0);
} else {
fprintf(stderr, "command not implemented\n");
struct cmd_spec *cmd;
if (!command || !strcmp(command, "help")) {
- printf("Usage xl <subcommand> [args]\n\n");
+ printf("Usage xl [-v] <subcommand> [args]\n\n");
printf("xl full list of subcommands:\n\n");
for (i = 0; i < cmdtable_len; i++)
printf(" %-20s%s\n",
} else {
cmd = cmdtable_lookup(command);
if (cmd) {
- printf("Usage: xl %s %s\n\n%s.\n\n",
+ printf("Usage: xl [-v] %s %s\n\n%s.\n\n",
cmd->cmd_name,
cmd->cmd_usage,
cmd->cmd_desc);